From: Jo-Philipp Wich Date: Tue, 14 Mar 2023 22:34:53 +0000 (+0100) Subject: luci-proto-wireguard: use ddns lookup_host for peer hints X-Git-Url: http://git.openwrt.org/%22https:/collectd.org//%22/%22https:/collectd.org/%22?a=commitdiff_plain;h=18a184243813092b1add700f4b8ef505eb7e79b9;p=project%2Fluci.git luci-proto-wireguard: use ddns lookup_host for peer hints The `domain` option of a DDNS service entry may contain non-hostname values, use the `lookup_hostname` option instead. Fixes: #6289 Signed-off-by: Jo-Philipp Wich (cherry picked from commit 59a6f062d29ee7a400e9cb0477e0e55eb674208a) --- diff --git a/protocols/luci-proto-wireguard/htdocs/luci-static/resources/protocol/wireguard.js b/protocols/luci-proto-wireguard/htdocs/luci-static/resources/protocol/wireguard.js index 068cc7b0c1..71b822adbf 100644 --- a/protocols/luci-proto-wireguard/htdocs/luci-static/resources/protocol/wireguard.js +++ b/protocols/luci-proto-wireguard/htdocs/luci-static/resources/protocol/wireguard.js @@ -732,8 +732,8 @@ return network.registerProtocol('wireguard', { var hostnames = []; uci.sections('ddns', 'service', function(s) { - if (typeof(s.domain) == 'string' && s.enabled == '1') - hostnames.push(s.domain); + if (typeof(s.lookup_host) == 'string' && s.enabled == '1') + hostnames.push(s.lookup_host); }); uci.sections('system', 'system', function(s) {